Health Cloud Medications System API - Implementation Template

(0 reviews)

Developer guide

Medications Dev Guide

The US-Core Medications application uses the following DataWeave modules to map between Health Cloud and FHIR formats.

ModuleDescription
fhirtoolsfhirtools DataWeave library (dw::Immunization::fhirtools) contains functions used for converting Health Cloud data into FHIR format.
fhirtoolsfhirtools DataWeave library (dw::Medication::fhirtools) contains functions used for converting Health Cloud data into FHIR format..
fhirtoolsfhirtools DataWeave library (dw::MedicationRequest::fhirtools) contains functions used for converting Health Cloud data into FHIR format..
fhirtoolsfhirtools DataWeave library (dw::MedicationStatement::fhirtools) contains functions used for converting Health Cloud data into FHIR format..
upsertGetRequestsThis module (dw::Immunization::upsertGetRequests) defines functions needed to convert a FHIR Immunization resource into it's representation within Health Cloud.
upsertGetRequestsThis module (dw::Medication::upsertGetRequests) defines functions needed to convert a FHIR Medication resource into it's representation within Health Cloud.
upsertGetRequestsThis module (dw::MedicationRequest::upsertGetRequests) defines functions needed to convert a FHIR MedicationRequest resource into it's representation within Health Cloud.
upsertGetRequestsThis module (dw::MedicationStatement::upsertGetRequests) defines functions needed to convert a FHIR MedicationStatement resource into it's representation within Health Cloud.

fhirtools

fhirtools DataWeave library (dw::Immunization::fhirtools) contains functions used for converting Health Cloud data into FHIR format.

Source: .src/main/resources/dwl/Immunization/fhirtools.dwl

Functions

fun getResponse (objRLU)

Generates the FHIR response with the provided Immunization Object.

param objRLU is the Immunization object to map.
return A Health Cloud Immunization response.

FHIR Field NameSalesforce Object NameSalesforce Field NameMapping Description
Identifier.useIdentifierIdUsageTypeValues: usual | official | temp | secondary | old
Identifier.systemIdentifierSourceSystemThe namespace for the identifier value.
Identifier.valueIdentifierIdValueThe value of the identifier.
Identifier.type.coding.systemIdentifierCodeSet.SourceSystemIdentity of the terminology system.
Identifier.type.coding.versionIdentifierCodeSet.SystemVersionVersion of the system.
Identifier.type.coding.codeIdentifierCodeSet.CodeThe code value.
Identifier.type.coding.displayIdentifierCodeSet.NameThe display value of the code.
Identifier.type.textIdentifierCodeSetBundle.NamePlain text representation of the identifier.
statusPatientImmunizationStatusValues: completed | entered-in-error | not-done
statusReason.coding.systemPatientImmunizationCodeSet.SourceSystemReason not done. Identity of the terminology system.
statusReason.coding.versionPatientImmunizationCodeSet.SystemVersionReason not done. Version of the system.
statusReason.coding.codePatientImmunizationCodeSet.CodeReason not done. The code value.
statusReason.coding.displayPatientImmunizationCodeSet.NameReason not done. Representation defined by the system.
statusReason.textPatientImmunizationCodeSetBundle.NameReason not done. Plain text representation of the concept.
vaccineCode.coding.systemPatientImmunizationCodeSet.SourceSystemVaccine product administered. Identity of the terminology system.
vaccineCode.coding.versionPatientImmunizationCodeSet.SystemVersionVaccine product administered. Version of the system.
vaccineCode.coding.codePatientImmunizationCodeSet.CodeVaccine product administered. The code value.
vaccineCode.coding.displayPatientImmunizationCodeSet.NameVaccine product administered. Representation defined by the system.
vaccineCode.textPatientImmunizationCodeSetBundle.NameVaccine product administered. Plain text representation of the concept.
patientPatientImmunizationPatientIdThe patient who was immunized.
encounterPatientImmunizationClinicalEncounterIdThe encounter the immunization was part of.
occurrenceDateTimePatientImmunizationVaccinationDateThe vaccine administration date datetime.
occurenceStringPatientImmunizationVaccinationPeriodThe vaccine administration date string.
recordedPatientImmunizationRecordCreationDateTimeWhen the immunization was first recorded.
primarySourcePatientImmunizationIsRecordedByVaccinatorIndicates context the data was recorded in.
reportOrigin.coding.systemPatientImmunizationCodeSet.SourceSystemThe source of the secondarily reported record. Identity of the terminology system.
reportOrigin.coding.versionPatientImmunizationCodeSet.SystemVersionThe source of the secondarily reported record. Version of the system.
reportOrigin.coding.codePatientImmunizationCodeSet.CodeThe source of the secondarily reported record. The code value.
reportOrigin.coding.displayPatientImmunizationCodeSet.NameThe source of the secondarily reported record. Representation defined by the system.
reportOrigin.textPatientImmunizationCodeSetBundle.NameThe source of the secondarily reported record. Plain text representation of the concept.
locationPatientImmunizationFacilityIdWhere the immunization occurred.
manufacturerPatientImmunizationManufacturerThe vaccine manufacture.
lotNumberPatientImmunizationLotNumberThe vaccine lot number.
expirationDatePatientImmunizationExpirationDateThe vaccine expiration date.
site.coding.systemPatientImmunizationCodeSet.SourceSystemThe body site the vaccine was administered. Identity of the terminology system.
site.coding.versionPatientImmunizationCodeSet.SystemVersionThe body site the vaccine was administered. Version of the system.
site.coding.codePatientImmunizationCodeSet.CodeThe body site the vaccine was administered. The code value.
site.coding.displayPatientImmunizationCodeSet.NameThe body site the vaccine was administered. Representation defined by the system.
site.textPatientImmunizationCodeSetBundle.NameThe body site the vaccine was administered. Plain text representation of the concept.
route.coding.systemPatientImmunizationCodeSet.SourceSystemHow the vaccine entered the body. Identity of the terminology system.
route.coding.versionPatientImmunizationCodeSet.SystemVersionHow the vaccine entered the body. Version of the system.
route.coding.codePatientImmunizationCodeSet.CodeHow the vaccine entered the body. The code value.
route.coding.displayPatientImmunizationCodeSet.NameHow the vaccine entered the body. Representation defined by the system.
route.textPatientImmunizationCodeSetBundle.NameHow the vaccine entered the body. Plain text representation of the concept.
doseQuantity.valuePatientImmunizationDoseThe amount of vaccine administered value.
doseQuantity.codePatientImmunizationUnitCodeThe amount of vaccine administered code.
performer.function.coding.systemCarePerformerCodeSet.SourceSystemWhat type of performance was done. Identity of the terminology system.
performer.function.coding.versionCarePerformerCodeSet.SystemVersionWhat type of performance was done. Version of the system.
performer.function.coding.codeCarePerformerCodeSet.CodeWhat type of performance was done. The code value.
performer.function.coding.displayCarePerformerCodeSet.NameWhat type of performance was done. Representation defined by the system.
performer.function.textCarePerformerCodeSetBundle.NameWhat type of performance was done. Plain text representation of the concept.
performer.actorCarePerformerPersonIdOrganization or individual doing the performing.
reasonCode.coding.systemPatientImmunizationCodeSet.SourceSystemWhy the immunization occurred. Identity of the terminology system.
reasonCode.coding.versionPatientImmunizationCodeSet.SystemVersionWhy the immunization occurred. Version of the system.
reasonCode.coding.codePatientImmunizationCodeSet.CodeWhy the immunization occurred. The code value.
reasonCode.coding.displayPatientImmunizationCodeSet.NameWhy the immunization occurred. Representation defined by the system.
reasonCode.textPatientImmunizationCodeSetBundle.NameWhy the immunization occurred. Plain text representation of the concept.
isSubpotentPatientImmunizationIsSubpotentThe dose potency.
subpotentReason.coding.systemPatientImmunizationCodeSet.SourceSystemThe reason for being subpoent. Identity of the terminology system.
subpotentReason.coding.versionPatientImmunizationCodeSet.SystemVersionThe reason for being subpoent. Version of the system.
subpotentReason.coding.codePatientImmunizationCodeSet.CodeThe reason for being subpoent. The code value.
subpotentReason.coding.displayPatientImmunizationCodeSet.NameThe reason for being subpoent. Representation defined by the system.
subpotentReason.textPatientImmunizationCodeSetBundle.NameThe reason for being subpoent. Plain text representation of the concept.
reasonReferencePatientImmunizationHealth​Condition​Id | Care​Observation​Id | Diagnostic​SummaryWhy the immunization occurred.
reaction.datePatient​Health​ReactionReaction​Date​TimeWhen the reaction started.
reaction.detailPatient​Health​ReactionObservation​IdInformation about the reaction.
reaction.reportedPatient​Health​ReactionIsSelf​ReportedWas the reaction self-reported.
protocolApplied.seriesPatientImmunizationImmunization​RecommendationThe name of the vaccine series.
protocolApplied.authorityPatientImmunizationRecommending​AuthorityThe organization who is responsible for publishing recommendations.
protocolApplied.targetDisease.coding.codePatientImmunizationTarget​Disease​​CodeIdThe preventable disease being targetted. The code value.
protocolApplied.doseNumberPositiveIntPatientImmunizationCurrentDoseThe dose number within the series.
protocolApplied.seriesDosesPositiveIntPatientImmunizationRecommended​DosesThe recommended number of doses for immunity.

fun getLinkSelf ()

Gets the URL to the current web resource.

return A string with the self link.

fun getEntryUrl (item: Object)

Gets the URL for the entry provided.

param item is an object with the item that's being returned.
return A string with the entry URL.

fun convertFhirIdentifierUse (toConvert)

Converts the provided Salesforce Identifier use value from its Health Cloud value to the corresponding FHIR value. If not matched, this function just returns the passed in value.

param toConvert is a string with the Health Cloud use value to convert.
return A string with the converted FHIR use value or the input value if not matched.

fun convertFhirStatus (sfStatus)

Converts the provided Salesforce Immunization status value from its Health Cloud value to the corresponding FHIR value. If not matched, this function just returns the passed in value.

param sfStatus is a string with the Health Cloud status value to convert.
return A string with the converted FHIR status value or the input value if not matched.

(back to top)

fhirtools

fhirtools DataWeave library (dw::Medication::fhirtools) contains functions used for converting Health Cloud data into FHIR format..

Source: .src/main/resources/dwl/Medication/fhirtools.dwl

Functions

fun getResponse (objRLU, unitOfMeasure)

Generates the Medication response object in FHIR format with associated objects queried from Health Cloud.

param objRLU is the Medication object along with related objects.
param unitOfMeasure is UnitOfMeasure codes.
return A FHIR formatted Medication object.

FHIR Field NameSalesforce Object NameSalesforce Field NameMapping Description
idAccountIdPatient account Id
Identifier.useIdentifierIdUsageTypeIdentifies the purpose for this identifier
identifier.systemIdentifierSourceSystemIdentifier system for resource
identifier.valueIdentifierIdValueIdentifier value for resource
identifier.type.codingIdentifierIdTypeIdDescription of identifier that references a CodeSetBundle (a CodeableConcept)
code.codingMedicationMedicationCodeIdCodes that identify this medication referencing a CodeSetBundle (a CodeableConcept)
statusMedicationStatusStatus of Medication as active or inactive or
manufacturerMedicationManufacturerIdManufacturer of the item
formMedicationMedicationFormIdForm of Medication like tablet or powder or any other form
amount.numerator.valueMedicationQuantityNumeratorQuantity Numerator to determine the amount of drug in package
amount.numerator.unitUnitOfMeasureUnitCodeUnit Code for numerator to determine the amount of drug in package
amount.denominator.valueMedicationQuantityDenominatorQuantity Denominator to determine the amount of drug in package
amount.denominator.unitUnitOfMeasureUnitCodeUnit Code of denominator to determine the amount of drug in package
ingredient.itemReferenceMedicinal​IngredientIngredientIdReference to an Ingredient item which can be an Ingredient or Substance. If its a Substance its stored as a CodeSetBundle (a CodeableConcept)
ingredient.isActiveMedicinal​IngredientIsActiveStatus of Ingredient like active or inactive
ingredient.strength.numerator.valueMedicinal​Ingredient​Strength​NumeratorStrength Numerator to determine the quantity of ingredient present
ingredient.strength.numerator.unitMedicinal​Ingredient​Strength​Numerator​UnitIdUnit Code for numerator to determine the quantity of ingredient present
ingredient.strength.denominator.valueMedicinal​Ingredient​Strength​DenominatorQuantity Denominator to determine the quantity of ingredient present
ingredient.strength.denominator.unitMedicinal​Ingredient​Strength​Denominator​UnitIdUnit Code of denominator to determine the quantity of ingredient present
ingredient.itemCodeableConceptMedicinal​IngredientIngredientIdReference to an Ingredient stored as a CodeSetBundle (a CodeableConcept)
batch.lotNumberMedicationBatch​NumberIdentifier assigned to batch
batch.expirationDateMedicationExpiration​DateTimeWhen batch will expire

fun getUnitOfMeasureUnitCode (unitOfMeasureCodes, unitCodeId)

Gets the UnitCode for an associated UnitId from UnitOfMeasure list.

param unitOfMeasureCodes is the UnitOfMeasure list that has all records
param unitCodeId is the codeId to filter the associated unit code.
return a UnitCode for an Id

fun getLinkSelf ()

Gets the URL to the current web resource.

return A string with the self link.

fun getEntryUrl (item: Object)

Gets the URL for the entry provided.

param item is an object with the item that's being returned.
return A string with the entry URL.

(back to top)

fhirtools

fhirtools DataWeave library (dw::MedicationRequest::fhirtools) contains functions used for converting Health Cloud data into FHIR format..

Source: .src/main/resources/dwl/MedicationRequest/fhirtools.dwl

Functions

fun getResponse (objRLU, codeSetLookupResponse, groupIdentifierLU)

Generates the FHIR response with the provided MedicationRequest Object.

param objRLU is the MedicationRequest object to map.
param codeSetLookupResponse is the lookup response for codesets.
param groupIdentifierLU is the groupIdentifier lookup response.
return A Health Cloud MedicationRequest response.

FHIR Field NameSalesforce Object NameSalesforce Field NameMapping Description
idMedicationRequestIdMedicationRequest Id
Identifier.useIdentifierIdUsageTypeIdentifies the purpose for this identifier
identifier.systemIdentifierSourceSystemIdentifier system for resource
identifier.valueIdentifierIdValueIdentifier value for resource
identifier.type.coding.codeIdentifierIdTypeIdDescription of identifier
statusMedicationRequestStatusMedicationRequest Status
statusReasonMedicationRequestStatusReasonCodeIdReason for current status
intentMedicationRequestTypeMedicationRequest intent
categoryMedicationRequestMedicationAdministrationContextIdGrouping or category of medication request
priorityMedicationRequestPriorityPriority of medication request
doNotPerformMedicationRequestIsIgnoredTrue if patient is to stop taking or not to start taking the medication
medicationCodeableConceptMedicationRequestMedicationCodeIdMedication to be taken
medicationReferenceMedicationRequestMedicationIdMedication to be taken
subjectMedicationRequestPatientIdWho or group medication request is for
reportedBooleanMedicationRequestIsSecondaryInformationReported rather than primary record
reportedReferenceMedicationRequestSecondarySourceIdReported rather than primary record
encounterMedicationRequestClinicalEncounterIdEncounter created as part of encounter or admission or stay
authoredOnMedicationRequestPrescribedDateWhen request was initially authored
requesterMedicationRequestRequesterIdWho or What requested the Request
performerMedicationRequestPerformerIdIntended performer of administration
performerTypeMedicationRequestPerformerTypeIdDesired kind of performer of the medication administration
reasonCodeMedicationRequestReasonCodeIdReason or indication for ordering or not ordering the medication
reasonReferenceMedicationRequestReasonReferenceIdCondition or observation that supports why the prescription is being written
basedOnMedicationRequestRelatedRequestIdA plan or request that is fulfilled this medication request
groupIdentifierMedicationRequestMedicationRequestGroupIdComposite request this is part of
courseOfTherapyTypeMedicationRequestTherapyDurationOverall pattern of medication administration
dosageInstruction.sequencePatientMedicationDosageSequenceThe order of the dosage instructions
dosageInstruction.textPatientMedicationDosageCommentsFree text dosage instructions
dosageInstruction.additionalInstruction.textPatientMedicationDosageAdditionalInstructionSupplemental instruction to the patient
dosageInstruction.patientInstructionPatientMedicationDosagePatientInstructionPatient or consumer oriented instructions
dosageInstruction.asNeededBooleanPatientMedicationDosageIsAsNeededThis value set includes all clinical findings
dosageInstruction.sitePatientMedicationDosageSiteIdBody site to administer to
dosageInstruction.routePatientMedicationDosageRouteIdHow drug should enter body
dosageInstruction.methodPatientMedicationDosageMethodIdTechnique for administering medication
dosageInstruction.doseAndRate.typePatientMedicationDosageDosageDefinitionTypeThe kind of dose or rate specified
dosageInstruction.doseAndRate.doseRange.low.valuePatientMedicationDosageDosageQuantityNumeratorLow limit
dosageInstruction.doseAndRate.doseRange.low.unitunitOfMeasureUnitCodeunit code value
dosageInstruction.doseAndRate.doseRange.high.valuePatientMedicationDosageDosageQuantityDenominatorHigh limit
dosageInstruction.doseAndRate.doseRange.high.unitunitOfMeasureUnitCodeunit code value
dosageInstruction.doseAndRate.doseQuantity.valuePatientMedicationDosageDosageQuantityNumeratorDose quantity value
dosageInstruction.doseAndRate.doseQuantity.unitunitOfMeasureUnitCodeunit code value
dosageInstruction.doseAndRate.rateRange.low.valuePatientMedicationDosageDosageRateNumeratorLow limit
dosageInstruction.doseAndRate.rateRange.low.unitunitOfMeasureUnitCodeunit code value
dosageInstruction.doseAndRate.rateRange.high.valuePatientMedicationDosageDosageRateDenominatorHigh limit
dosageInstruction.doseAndRate.rateRange.high.unitunitOfMeasureUnitCodeunit code value
dosageInstruction.doseAndRate.rateRatio.low.valuePatientMedicationDosageDosageRateNumeratorLow limit
dosageInstruction.doseAndRate.rateRatio.low.unitunitOfMeasureUnitCodeunit code value
dosageInstruction.doseAndRate.rateRatio.high.valuePatientMedicationDosageDosageRateDenominatorHigh limit
dosageInstruction.doseAndRate.rateRatio.high.unitunitOfMeasureUnitCodeunit code value
dosageInstruction.doseAndRate.rateQuantity.valuePatientMedicationDosageDosageRateNumeratorDose rate value
dosageInstruction.doseAndRate.rateQuantity.unitunitOfMeasureUnitCodeunit code value
dispenseRequest.initialFill.quantity.valueMedicationRequestInitialFillQuantityFirst fill details
dispenseRequest.initialFill.quantity.unitMedicationRequestFillQuantityUnitIdunit code value
dispenseRequest.initialFill.duation.valueMedicationRequestInitialFillDurationFirst fill duration
dispenseRequest.initialFill.duation.unitMedicationRequestFillDurationUnitIdunit code value
dispenseRequest.initialFill.dispenseInterval.valueMedicationRequestDispenseIntervalMinimum period of time between dispenses
dispenseRequest.initialFill.dispenseInterval.unitMedicationRequestDispenseIntervalUnitIdunit code value
dispenseRequest.validityPeriod.startMedicationRequestPrescriptionPeriodStartTime period supply is authorized for
dispenseRequest.validityPeriod.endMedicationRequestPrescriptionPeriodEndTime period supply is authorized for
dispenseRequest.numberOfRepeatsAllowedMedicationRequestRefillsAllowedNumber of refills authorized
dispenseRequest.quantity.valueMedicationRequestRefillQuantityAmount of medication to supply per dispense
dispenseRequest.quantity.unitMedicationRequestFillQuantityUnitIdunit code value
dispenseRequest.expectedSupplyDuration.valueMedicationRequestRefillDurationNumber of days supply per dispense
dispenseRequest.expectedSupplyDuration.unitMedicationRequestFillDurationUnitIdunit code value
dispenseRequest.performerMedicationRequestDispenserIdIntended dispenser
substitution.allowedBooleanMedicationRequestCanSubstituteWhether substitution is allowed or not
substitution.allowedCodeableConceptMedicationRequestAllowedSubstitutionTypeCodeIdWhether substitution is allowed or not
substitution.reasonMedicationRequestSubstitutionReasonCodeIdWhy should (not) substitution be made
priorPrescriptionMedicationRequestPreviousPrescriptionIdReference to prescription that is being replaced by this MedicationRequest

fun getUnitOfMeasureCode (unitOfMeasureCodes, unitCodeId)

Gets the UnitCode for an associated ID from UnitOfMeasure list.

param unitOfMeasureCodes is the UnitOfMeasure list that has all records
param unitCodeId is the Id to filter the associated unitCode.
return an unitCode for the Id

fun getLinkSelf ()

Gets the URL to the current web resource.

return A string with the self link.

fun getEntryUrl (item: Object)

Gets the URL for the entry provided.

param item is an object with the item that's being returned.
return A string with the entry URL.

(back to top)

fhirtools

fhirtools DataWeave library (dw::MedicationStatement::fhirtools) contains functions used for converting Health Cloud data into FHIR format..

Source: .src/main/resources/dwl/MedicationStatement/fhirtools.dwl

Functions

fun getResponse (objRLU, fhirCodeSetCategory, fhirCodeSetDosageType)

Generates the FHIR response with the provided MedicationStatement Object.

param objRLU is the MedicationStatement object to map.
param fhirCodeSetCategory is FHIR Codeset object for Category.
param fhirCodeSetDosageType is FHIR Codeset object for DosageType.
return A Health Cloud MedicationStatement response.

FHIR Field NameSalesforce Object NameSalesforce Field NameMapping Description
idMedicationStatementIdMedicationStatement Id
Identifier.useIdentifierIdUsageTypeIdentifies the purpose for this identifier
identifier.systemIdentifierSourceSystemIdentifier system for resource
identifier.valueIdentifierIdValueIdentifier value for resource
identifier.type.coding.codeIdentifierIdTypeIdDescription of identifier
identifier.period.startIdentifierEffectiveDateStarting time with inclusive boundary
identifier.period.endIdentifierEndDateEnd time with inclusive boundary
identifier.assignerIdentifierIssuingAuthorityIdOrganization that issued id (may be just text)
statusMedicationStatementStatusThe status of the diagnostic report.
basedOnMedicationStatementMedicationRequestIdDetails concerning a service requested.
contextMedicationStatementClinicalEncounterIdEncounter or Episode associated with MedicationStatement
subjectMedicationStatementPatientIdWho is taking the medication
dateAssertedMedicationStatementAssertionDateTimeWhen the statement was asserted?
partOfMedicationStatementParentMedicationStatementId or ProcedureId or CareObservationIdPart of referenced event
statusReason.coding.codeMedicationStatementStatusReasonCodeIdReason for current status
category.coding.codeMedicationStatementDeliverySettingType of medication usage
medicationCodeableConcept.coding.codeMedicationStatementMedicationCodeIdWhat medication was taken
medicationReferenceMedicationStatementMedicationIdWhat medication was taken
effectiveDateTimeMedicationStatementStartDateTimeThe date & time when the medication is taken
effectivePeriod.startMedicationStatementStartDateTimeThe interval when the medication is taken
effectivePeriod.endMedicationStatementEndDateTimeThe interval when the medication is taken
informationSourceMedicationStatementStatementSourceIdWhen the statement was asserted?
reasonCode.coding.codeMedicationStatementMedicationReasonCodeIdReason for why the medication is being taken
reasonReferenceMedicationStatementMedicationReasonIdReason for why the medication is being taken
dosagePatientMedicationDosageDosage instructions
dosage.sequencePatientMedicationDosageSequenceThe order of the dosage instructions
dosage.textPatientMedicationDosageCommentsFree text dosage instructions
dosage.additionlInstruction.coding.codePatientMedicationDosageAdditionalInstructionSupplemental instruction or warnings to the patient
dosage.patientInstructionPatientMedicationDosagePatientInstructionPatient or consumer oriented instructions
dosage.timing.codePatientMedicationDosageTimingIdWhen medication should be administered
dosage.asNeededBooleanPatientMedicationDosageIsAsNeededTake as needed
dosage.site.coding.codePatientMedicationDosageSiteIdBody site to administer to
dosage.route.coding.codePatientMedicationDosageRouteIdHow drug should enter body
dosage.method.coding.codePatientMedicationDosageMethodIdTechnique for administering medication
dosage.doseAndRate.type.coding.codePatientMedicationDosageDosageDefinitionTypeAmount of medication per dose
dosage.doseAndRate.doseQuantity.codePatientMedicationDosageDosageQuantityTypeAmount of medication per dose
dosage.doseAndRate.doseQuantity.valuePatientMedicationDosageDosageQuantityNumeratorAmount of medication per dose
dosage.doseAndRate.doseQuantity.unitPatientMedicationDosageDosageUnitIdAmount of medication per dose
dosage.doseAndRate.rate.numerator.codePatientMedicationDosageDosageRateTypeAmount of medication per unit of time
dosage.doseAndRate.rate.numerator.valuePatientMedicationDosageDosageRateNumeratorAmount of medication per unit of time
dosage.doseAndRate.rate.denominator.unitPatientMedicationDosageDosageRateUnitIdAmount of medication per unit of time
dosage.doseAndRate.rate.denominator.valuePatientMedicationDosageDosageRateDenominatorAmount of medication per unit of time

fun getLinkSelf ()

Gets the URL to the current web resource.

return A string with the self link.

fun getEntryUrl (item: Object)

Gets the URL for the entry provided.

param item is an object with the item that's being returned.
return A string with the entry URL.

(back to top)

upsertGetRequests

This module (dw::Immunization::upsertGetRequests) defines functions needed to convert a
FHIR Immunization resource into it's representation within
Health Cloud.

Source: .src/main/resources/dwl/Immunization/upsertGetRequests.dwl

Functions

fun getResultIds (res)

This function takes the results of a Salesforce query and returns a list of IDs.

param res is a Salesforce query result.
return An array with a list of Ids found.

fun getImmunizationUpsert (fhirObj, codeSetBundleList, quantityUnitId)

Converts the provided Immunization FHIR object to the Health Cloud Immunization object.

param fhirObj is a FHIR Immunization object.
param codeSetBundleList is the list of CodeSetBundle objects for the Immunization object
param quantityUnitId is a UnitCode from UnitOfMeasure object.
return Health Cloud Immunization upsert fields.

fun getImmunizationUpdate (fhirObj, codeSetBundleList, quantityUnitId)

Converts the provided Immunization FHIR object to the Health Cloud Immunization object.

param fhirObj is a FHIR Immunization object.
param codeSetBundleList is the list of CodeSetBundle objects for the Immunization object
param quantityUnitId is a UnitCode from UnitOfMeasure object.
return Health Cloud Immunization update fields.

fun getCarePerformer (identifier, parentRecordId, CarePerformerParentsRoleId)

Converts the provided Immunization FHIR object to the Health Cloud CarePerformer object.

param identifier is a FHIR Identifier object.
param parentRecordId is the ImmunizationId
param CarePerformerParentsRoleId is the RoleId (CodeSetBundle)
return Health Cloud Immunization upsert fields.

fun getPatientHealthReaction (parentRecordId, reaction)

Converts the provided Immunization FHIR object to the Heath Cloud PatientHealthReaction object.

param parentRecordId is the PatientImmunization ID.
param reaction is the Immunization.reaction object.
return A Health Cloud PatientHealthReaction upsert object.

fun getCodeSetUpsert (codeSetList)

Converts the provided Immunization FHIR object to the Health Cloud CodeSet object.

param codeSetList is the list of codeSet object.
return Health Cloud CodeSet upsert fields.

fun getCodeSetBundleUpsert (codeSetList, bundleType, name)

Converts the provided Immunization FHIR object to the Health Cloud CodeSetBundle object.

param codeSetList is the list of CodeSetBundle object.
param bundleType is for defining the CodeSetBundle type.
param name is for defining the name of the CodeSetBundle.
return Health Cloud CodeSetBundle upsert fields.

fun getIdentifierUpsert (identifier, parentRecordId, typeId)

Converts the provided Immunization FHIR object to the Health Cloud Identifier object.

param identifier is the list of Identifier object.
param parentRecordId is the associated Immunization Id
param typeId is the IdTypeId (CodesetBundle) of Identifier
return Health Cloud Identifier upsert fields.

fun convertSalesforceIdentifierUse (toConvert)

Converts the provided FHIR Identifier use value from its FHIR value to the corresponding Health Cloud value. If not matched, this function just returns the passed in value.

param toConvert is a string with the FHIR use value to convert.
return A string with the converted Health Cloud use value or the input value if not matched.

fun convertSalesforceStatus (fhirStatus)

Converts the provided FHIR Immunization status value from its FHIR value to the corresponding Health Cloud value. If not matched, this function just returns the passed in value.

param fhirStatus is a string with the FHIR status value to convert.
return A string with the converted Health Cloud status value or the input value if not matched.

(back to top)

upsertGetRequests

This module (dw::Medication::upsertGetRequests) defines functions needed to convert a
FHIR Medication resource into it's representation within
Health Cloud.

Source: .src/main/resources/dwl/Medication/upsertGetRequests.dwl

Functions

fun getResultIds (res)

This function takes the results of a Salesforce query and returns a list of IDs.

param res is a Salesforce query result.
return An array with a list of Ids found.

fun getMedicationUpsert (fhirObj, codeSetBundleList, unitOfMeasureCodes)

Converts the provided Medication FHIR object to the Health Cloud Medication object.

param fhirObj is a FHIR Medication object.
param codeSetBundleList is the list of CodeSetBundle objects for the Medication object
param unitOfMeasureCodes is a UnitCode from UnitOfMeasure object. which references to UnitOfMeasure Object
return Health Cloud Medication upsert fields.

fun getMedicationUpdate (fhirObj, codeSetBundleList, unitOfMeasureCodes)

Converts the provided Medication FHIR object to the Health Cloud Medication object.

param fhirObj is a FHIR Medication object.
param codeSetBundleList is the list of CodeSetBundle objects for the Medication object
param unitOfMeasureCodes is a UnitCode from UnitOfMeasure object. which references to UnitOfMeasure Object
return Health Cloud Medication upsert fields.

fun getCodeSetUpsert (codeSetList)

Converts the provided Medication FHIR object to the Health Cloud CodeSet object.

param codeSetList is the list of codeSet object.
return Health Cloud CodeSet upsert fields.

fun getCodeSetBundleUpsert (codeSetList, bundleType, name)

Converts the provided Medication FHIR object to the Health Cloud CodeSetBundle object.

param codeSetList is the list of CodeSetBundle object.
param bundleType is for defining the CodeSetBundle type.
param name is for defining the name of the CodeSetBundle.
return Health Cloud CodeSetBundle upsert fields.

fun getIdentifierUpsert (identifier, parentRecordId, typeId)

Converts the provided Medication FHIR object to the Health Cloud Identifier object.

param identifier is the list of Identifier object.
param parentRecordId is the associated Medication Id
param typeId is the IdTypeId (CodesetBundle) of Identifier
return Health Cloud Identifier upsert fields.

fun getIngredientUpsert (ingredient, parentRecordId, ingredientId, unitOfMeasureCodes)

Converts the provided ingredient FHIR object to the Health Cloud MedicinalIngredient object.

param ingredient is the list of ingredient objects.
param parentRecordId is the associated Medication Id
param unitOfMeasureCodes is unit of measure from UnitOfMesaure Object
return Health Cloud Identifier upsert fields.

fun getUnitOfMeasureCodeId (unitOfMeasureCodes, unitCode)

Gets the Id for an associated UnitCode from UnitOfMeasure list.

param unitOfMeasureCodes is the UnitOfMeasure list that has all records
param unitCode is the unitCode to filter the associated unit Id.
return an Id for the unitCode

(back to top)

upsertGetRequests

This module (dw::MedicationRequest::upsertGetRequests) defines functions needed to convert a
FHIR MedicationRequest resource into it's representation within
Health Cloud.

Source: .src/main/resources/dwl/MedicationRequest/upsertGetRequests.dwl

Functions

fun getResultIds (res)

This function takes the results of a Salesforce query and returns a list of IDs.

param res is a Salesforce query result.
return An array with a list of Ids found.

fun getMedicationRequestUpsert (fhirObj, codeSetBundleList, unitOfMeasureCodes, upsertLookupResponse, groupIdentifierId)

Converts the provided MedicationRequest FHIR object to the Health Cloud MedicationRequest object.

param fhirObj is a FHIR MedicationRequest object.
param codeSetBundleList is the list of CodeSetBundle objects for the MedicationRequest object
return Health Cloud MedicationRequest upsert fields.

fun getMedicationRequestUpdate (fhirObj, codeSetBundleList, unitOfMeasureCodes, upsertLookupResponse, groupIdentifierId)

Converts the provided MedicationRequest FHIR object to the Health Cloud MedicationRequest object.

param fhirObj is a FHIR MedicationRequest object.
param codeSetBundleList is the list of CodeSetBundle objects for the MedicationRequest object
return Health Cloud MedicationRequest update fields.

fun getPMDosageUpsert (fhirObj, codeSetBundleList, acc_QuantityUnitId_doseQuantity, acc_QuantityUnitId_rateQuantity, index, parentId, unitOfMeasureCodes)

Converts the provided dosageInstruction FHIR object to the Health Cloud PatientMedicationDosage object.

param fhirObj is a FHIR MedicationRequest object.
param codeSetBundleList is the List of codeSetBundle Ids
param acc_QuantityUnitId_doseQuantity is the List of doseQuantity Ids
param acc_QuantityUnitId_rateQuantity is the List of rateQuantity Ids
param index is PatientMedicationDosage index
param parentId is the ParentRecordId
return A Health Cloud MedicationRequest object.

fun getCodeSetUpsert (codeSetList)

Converts the provided MedicationRequest FHIR object to the Health Cloud CodeSet object.

param codeSetList is the list of codeSet object.
return Health Cloud CodeSet upsert fields.

fun getCodeSetBundleUpsert (codeSetList, bundleType, name)

Converts the provided MedicationRequest FHIR object to the Health Cloud CodeSetBundle object.

param codeSetList is the list of CodeSetBundle object.
param bundleType is for defining the CodeSetBundle type.
param name is for defining the name of the CodeSetBundle.
return Health Cloud CodeSetBundle upsert fields.

fun getIdentifierUpsert (identifier, parentRecordId, typeId)

Converts the provided MedicationRequest Identifier FHIR object to the Health Cloud Identifier object.

param identifier is the list of Identifier object.
param parentRecordId is the associated MedicationRequest Id
param typeId is the IdTypeId (CodesetBundle) of Identifier
return Health Cloud Identifier upsert fields.

fun getPickListValue (inputValue, lookupValue)

Converts the FHIR CodeableConcept fields and result from lookup to get the values for picklist field used in MedicationRequest upsert.

param inputValue is a FHIR object field, lookupValue is from FHIRCodeSetc. return_ value for the picklist field.

fun getUnitOfMeasureCodeId (unitOfMeasureCodes, unitCode)

Gets the Id for an associated UnitCode from UnitOfMeasure list.

param unitOfMeasureCodes is the UnitOfMeasure list that has all records
param unitCode is the unitCode to filter the associated unit Id.
return an Id for the unitCode

(back to top)

upsertGetRequests

This module (dw::MedicationStatement::upsertGetRequests) defines functions needed to convert a
FHIR MedicationStatement resource into it's representation within
Health Cloud.

Source: .src/main/resources/dwl/MedicationStatement/upsertGetRequests.dwl

Functions

fun getResultIds (res)

This function takes the results of a Salesforce query and returns a list of IDs.

param res is a Salesforce query result.
return An array with a list of Ids found.

fun getPickListValue (req, lookupReq)

Converts the FHIR CodeableConcept fields and result from lookup to get the values for picklist field used in Encounter upsert.

param req is a FHIR object field, lookupReq is from FHIRCodeSetc. return_ value for the picklist field.

fun getPMDosageUpsert (fhirObj, codeSetBundleList, QuantityUnitId, index, parentId, fhirCodeSetDosageType)

Converts the provided dosage FHIR object to the Health Cloud PatientMedicationDosage object.

param fhirObj is a FHIR MedicationRequest object.
param codeSetBundleList is the List of codeSetBundle Ids
param QuantityUnitId is the List of UnitOfMeasure CodeSet bundles
param index is PatientMedicationDosage index
param parentId is the ParentRecordId
return A Health Cloud MedicationRequest object.

fun getmedicationStatementUpsert (fhirObj, codeSetBundleList, quantityUnitId, fhirCodeSetCategory)

Converts the provided MedicationStatement FHIR object to the Health Cloud MedicationStatement object.

param fhirObj is a FHIR MedicationStatement object.
param codeSetBundleList is the list of CodeSetBundle objects for the MedicationStatement object
param quantityUnitId is a UnitCode from UnitOfMeasure object.
param fhirCodeSetCategory is CodeSet Object for Category
return Health Cloud MedicationStatement upsert fields.

fun getmedicationStatementUpdate (fhirObj, codeSetBundleList, quantityUnitId, fhirCodeSetCategory)

Converts the provided MedicationStatement FHIR object to the Health Cloud MedicationStatement object.

param fhirObj is a FHIR MedicationStatement object.
param codeSetBundleList is the list of CodeSetBundle objects for the MedicationStatement object
param quantityUnitId is a UnitCode from UnitOfMeasure object.
param fhirCodeSetCategory is CodeSet Object for Category
return Health Cloud MedicationStatement update fields.

fun getCodeSetUpsert (codeSetList)

Converts the provided MedicationStatement FHIR object to the Health Cloud CodeSet object.

param codeSetList is the list of codeSet object.
return Health Cloud CodeSet upsert fields.

fun getCodeSetBundleUpsert (codeSetList, bundleType, name)

Converts the provided FHIR MedicationStatement object to the Health Cloud CodeSetBundle object.

param codeSetList is the list of CodeSetBundle object.
param bundleType is for defining the CodeSetBundle type.
param name is for defining the name of the CodeSetBundle.
return Health Cloud CodeSetBundle upsert fields.

fun getIdentifierUpsert (identifier, parentRecordId, typeId)

Converts the provided MedicationStatement FHIR object to the Health Cloud Identifier object.

param identifier is the list of Identifier object.
param parentRecordId is the associated MedicationStatement Id
param typeId is the IdTypeId (CodesetBundle) of Identifier
return Health Cloud Identifier upsert fields.

(back to top)


Reviews

TypeTemplate
OrganizationMulesoft Inc.
Published by
MuleSoft Solutions
Published onJan 8, 2024
Asset overview

Asset versions for 1.0.x

Asset versions
VersionActions
1.0.8
1.0.7
1.0.6
1.0.5
1.0.4
1.0.3
1.0.2
1.0.1